package com.cacshanghai.cac_oa_client.ui;

import android.app.Fragment;
import android.content.Intent;
import android.os.Bundle;
import android.support.annotation.Nullable;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.LinearLayout;
import android.widget.TextView;

import com.cacshanghai.cac_oa_client.R;

/**
 * Created by geyh on 2016/5/24.
 */
public class LeaveFragment extends HomePageBaseFragment {

    private LinearLayout ll_handler_leave, ll_refuse_leave;

    @Nullable
    @Override
    public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
        return inflater.inflate(R.layout.fragment_leave, container, false);
    }

    @Override
    public void onActivityCreated(Bundle savedInstanceState) {
        super.onActivityCreated(savedInstanceState);

        setTitle(getResources().getString(R.string.my_leave));
        setTitleBackgroundColor(R.color.light_orange);
        setTitleOnClickToPage(LeaveActivity.class);

        ll_handler_leave = (LinearLayout) getView().findViewById(R.id.ll_handler_leave);
        ll_handler_leave.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(getActivity(), LeaveActivity.class);
                startActivity(intent);
            }
        });

        ll_refuse_leave = (LinearLayout) getView().findViewById(R.id.ll_refuse_leave);
        ll_refuse_leave.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(getActivity(), LeaveActivity.class);
                startActivity(intent);
            }
        });

    }

}
